package com.maiji.cloud.entities.shopingmall;

import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.Version;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.annotation.Table;
import com.gitee.sunchenbin.mybatis.actable.constants.MySqlTypeConstant;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.util.Date;

/**
 * Description:  资金主表
 * @author zhanglr  
 * @date 2019年6月25日
 */
@NoArgsConstructor
@Data
@Accessors(chain = true)
@Table(name = "capital_main")
public class CapitalMain {

	@TableId
	@Column(name = "uu_id", type = MySqlTypeConstant.VARCHAR, length = 50, isKey = true)
	private String uuId;
	
	@Column(name = "user_id", type = MySqlTypeConstant.VARCHAR, length = 50)
	private String userId;
	
	@Column(name = "money", type = MySqlTypeConstant.DOUBLE, length = 8, decimalLength = 2, defaultValue = "0.00")
	private Double money; // 账户余额

	@Column(name = "return_money", type = MySqlTypeConstant.DOUBLE, length = 8, decimalLength = 2, defaultValue = "0.00")
	private Double returnMoney; // 订单返现资金
	
	@Column(name = "frozen_capital", type = MySqlTypeConstant.DOUBLE, length = 8, decimalLength = 2, defaultValue = "0.00")
	private Double frozenCapital; // 分销冻结资金

	@Column(name = "distribution_Money", type = MySqlTypeConstant.DOUBLE, length = 8, decimalLength = 2, defaultValue = "0.00")
	private Double distributionMoney; // 分销可提资金
	
	@Column(name = "fund", type = MySqlTypeConstant.DOUBLE, length = 8, decimalLength = 2, defaultValue = "0.00")
	private Double fund; // 减肥基金
	
	@Column(name = "integral", type = MySqlTypeConstant.INT, length = 2, defaultValue = "0")
	private Integer integral; //积分

	@Column(name = "pay_password", type = MySqlTypeConstant.VARCHAR, length = 50)
	private String payPassword; //支付密码
	
    @Column(name = "update_date", type = MySqlTypeConstant.DATETIME)
    private Date updateDate; // 资金最近变动时间 
   
    @Version
	@Column(name = "version", type = MySqlTypeConstant.INT, length = 1, defaultValue = "0")
	private Integer version; // 数据版本号

}
